package system.service.impl;

import common.entity.MyPageResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import system.entity.SysUser;
import system.mapper.SysUserMapper;
import system.service.SysUserService;

/**
 * 系统用户业务层接口实现类
 * @author 宜春学院
 */
@Service
public class SysUserServiceImpl implements SysUserService {
    /**
     * 在系统用户业务层接口实现类中注入，系统用户持久层
     */
    @Autowired
    private SysUserMapper sysUserMapper;

    @Override
    public int insertSysUser(SysUser sysUser) {
        return sysUserMapper.insertSysUser(sysUser);
    }

    @Override
    public int deleteSysUser(int[] ids) {
        return sysUserMapper.deleteSysUser(ids);
    }

    @Override
    public void updateSysUser(SysUser sysUser) {
        sysUserMapper.updateSysUser(sysUser);
    }

    @Override
    public MyPageResult<SysUser> selectSysUser(SysUser sysUser) {
        return sysUserMapper.selectSysUser(sysUser);
    }

    @Override
    public SysUser selectSysUserById(Long id) {
        return sysUserMapper.selectSysUserById(id);
    }
}